import axios from "../request";

// 获取部门树形数据
export const getDepartmentArrApi = (params) =>
	axios({
		url: "/system/department",
		params,
	});

// 删除部门
export const deleteDepartmentApi = (data) =>
	axios({
		url: "/system/department",
		method: "delete",
		data,
	});

// 新增部门
export const addDepartmentApi = (data) =>
	axios({
		url: "/system/department",
		method: "post",
		data,
	});

// 编辑部门
export const editDepartmentApi = (data) =>
	axios({
		url: "/system/department",
		method: "put",
		data,
	});
